var userid = document.URL.split("?")[1].split("&")[0].split("=")[1];

				
				//
				var pinHt = "";
				var pinHttt = "";

				var pinHtN = "";
				var pinHtttN = "";
				var pinHtN2 = "";
				var pinHtttN2 = "";

				var pinHtD = "";
				var pinHtttD = "";
				var pinHtD2 = "";
				var pinHtttD2 = "";

				//恩爱战场搜索

				function searchQ(eaval, $list, pinht, type, $search) {
					//	var eaval = $inp.val();
					if(eaval.length == 0) {
						//		console.log("进来了");
						$list.empty();
						$list.append(pinht);
					} else {
						$.ajax({
							url: 'http://test.onetuu.com/Valentines/search', //跨域到http://www.wp.com，另，http://test.com也算跨域
							type: 'post', //jsonp 类型下只能使用GET,不能用POST,这里不写默认为GET
							dataType: 'json', //指定为jsonp类型
							data: {
								"userid":userid,
								"type": type,
								"name": eaval
							},
							success: function(data) {
								console.log(data);
								$list.empty();
								pinHtN2 = "";
								pinHtttN2 = "";
								
								if(data.data == null){
									$list.parent().css("height","95vh");
									$list.parent().css("background","url(img/none.png)no-repeat");
									$list.parent().css("background-size","100% 100%")
								}else{
									$list.parent().css("height","auto");
									$list.parent().css("background","transparent");
								}

								for(var i = 0; i < data.data.length; i++) {
									//点赞

									if(data.data[i].duihua == null) {
										$(".pinglun_huifu").hide();
										pinHtN2 += `<li class="comment_li">
											<div class="comment_li_tou">
												<div class="commenttouxiang">
													<img src="` + data.data[i].avatarDomain + `" />
												</div>
												<div class="commentnicheng">
													<div class="commentname">
														` + data.data[i].name + `
													</div>
													<div class="commenttime">
														` + data.data[i].create + `
													</div>
												</div>
											</div>
											<div class="commentimg">
												<img src="` + data.data[i].img + `" /><span></span>
											</div>
											<div class="commentword">
												` + data.data[i].discourse + `
											</div>
											<hr />
											<div class="commentPoint">
												<div class="commentPointzan" thumbup="` + data.data[i].thumbup + `" commentId="` + data.data[i].commentId + `">
													<img src="img/zan.png" class="` + data.data[i].thumbup + `"/>
													<span>
														` + data.data[i].dznum + `
													</span>
												</div>
												<div class="commentPointall" id="couplesping" commentId="` + data.data[i].commentId + `" name="` + data.data[i].name + `">
													<img src="img/zong.png" />
													<span>
														` + data.data[i].plnum + `
													</span>
												</div>

											</div>
											<div class="pinglun_huifu">
												<ul class="pinglun_huifu_neirong" style="display:none" commentId="` + data.data[i].commentId + `">
													
												</ul>
											</div>
											
										</li>`
									} else if(data.data[i].duihua.length > 0) {
										console.log(data.data[i].duihua.length);
										for(var j = 0; j < data.data[i].duihua.length; j++) {
											pinHtttN2 += `<li>
												<div class="pinglun_huifu_neirong_name" style="line-hight:.2rem">
														<em style="color:#6db0ff">
															` + data.data[i].duihua[j].name + `
														</em>：
															` + data.data[i].duihua[j].discourse + `
																
												</div>
												

											</li>`
										}

										pinHtN2 += `<li class="comment_li">
											<div class="comment_li_tou">
												<div class="commenttouxiang">
													<img src="` + data.data[i].avatarDomain + `" />
												</div>
												<div class="commentnicheng">
													<div class="commentname">
														` + data.data[i].name + `
													</div>
													<div class="commenttime">
														` + data.data[i].create + `
													</div>
												</div>
											</div>
											<div class="commentimg">
												<img src="` + data.data[i].img + `" /><span></span>
											</div>
											<div class="commentword">
												` + data.data[i].discourse + `
											</div>
											<hr />
											<div class="commentPoint">
												<div class="commentPointzan" thumbup="` + data.data[i].thumbup + `" commentId="` + data.data[i].commentId + `">
													<img src="img/zan.png" class="` + data.data[i].thumbup + `"/>
													<span>
														` + data.data[i].dznum + `
													</span>
												</div>
												<div class="commentPointall" id="couplesping" commentId="` + data.data[i].commentId + `" name="` + data.data[i].name + `">
													<img src="img/zong.png" />
													<span>
														` + data.data[i].plnum + `
													</span>
												</div>

											</div>
											<div class="pinglun_huifu">
												<ul class="pinglun_huifu_neirong"  commentId="` + data.data[i].commentId + `">
													` + pinHtttN2 + `
												</ul>
												<div class="showmore1">查看更多&gt;</div>
											</div>
										</li>`
									}
									pinHtttN2 = "";
								}
								$list.append(pinHtN2);
								//								pinHtN = "";
								$(window).unbind('scroll');
								$(window).scroll(function() {
									var h = $search.outerHeight();
									$(".swiper-container").height($list.height() + h);
								});
								$(".showmore1,.showmore").on("touchend", function() {
									$(this).parent().css("display", "block");
									$(this).parent().css("-webkit-line-clamp", "initial");
									$(this).css("display", "none");

								});
								$(".commentimg").on("click", function() {
			
									var thisImg = $(this).find("img").attr("src");
									$(".black").show();
									$(".black").find("img").attr("src", thisImg);
									$(".black").find("img").on("click", function() {
										$(".black").hide();
									});
			
								});
								$(".black").on("click", function() {
									$(".black").hide();
								});

							}
						});
					}

				}

				$("#enaiS").on("touchend", function() {

					var eaval = $(".enaiinput").val();
					var $list = $('.comment_centerN');
					var pinht = pinHtN;
					var type = 1;
					var $search = $('.enaisearch');
					searchQ(eaval, $list, pinht, type, $search);
					

				});
				//单身战场搜索
				$("#danS").on("touchend", function() {
					var dsval = $(".dansheninput").val();
					var $list = $('.comment_centerD');
					var pinht = pinHtD;
					var type = 2;
					var $search = $('.danshensearch');
					searchQ(dsval, $list, pinht, type, $search);
					
				});

			
//				
			





